<template>
  <span class="title" v-show="title">
    {{ title }}
    <el-popover
      v-if="tip"
      placement="top-start"
      width="200"
      trigger="hover"
      :content="tip">
      <i class="el-icon-question" slot="reference"></i>
    </el-popover>
  </span>
</template>

<script>
  export default {
    name: 'FormTitle',
    props: {
      title: {
        type: String,
        default: () => ''
      },
      tip: {
        type: String,
        default: () => ''
      }
    }
  }
</script>

<style scoped lang="scss">
  .title{
    color: #333;
    font-weight: 700;
    padding-left: 10px;
    border-left: black solid 2px;
    margin-bottom: 10px;
  }
</style>
